home *** CD-ROM | disk | FTP | other *** search
/ Shareware Grab Bag / Shareware Grab Bag.iso / 003 / db3.arc / INVEDIT.PRG < prev    next >
Encoding:
Text File  |  1984-10-25  |  2.0 KB  |  57 lines

  1. * Invedit.prg
  2. Changing = 'Y'
  3. DO WHILE UPPER(Changing) = 'Y'
  4.    SELECT 1
  5.    GO TOP
  6.    IF EOF()
  7.       WAIT 'There are no INVOICES in the entry file.  Type any key to proceed'
  8.       Changing = 'N'
  9.    ELSE
  10.       CLEAR
  11.       WAIT 'Do you want to print the listing now (Y or N)? ' TO Hardcopy
  12.       CLEAR
  13.       ? 'These are the INVOICES in the entry file.'
  14.       ? 'After they are displayed, enter the number to EDIT.'
  15.       ?
  16.       IF UPPER(Hardcopy) = 'Y'
  17.      SET PRINT ON
  18.       ENDIF
  19.       ? ' INV #  JOB #    DESCRIPTION                    TAXABLE';
  20.           + '     TAX        NO TAX'
  21.       ?
  22.       DISPLAY FOR .NOT. DELETED() Inv_Nmbr,Client +'-'+ STR(Job_Nmbr,4),;
  23.           SUBSTR(Descrip,1,26), Taxable, Sales_Tax, TaxFree OFF
  24.       SET PRINT OFF
  25.       ACCEPT 'Enter INVOICE NUMBER to EDIT, <ENTER> to exit ' TO T_Inv_Nmbr
  26.       IF LEN(T_Inv_Nmbr) <> 0
  27.      LOCATE FOR Inv_Nmbr = T_Inv_Nmbr
  28.      IF EOF()
  29.               ?
  30.         ?
  31.         ? T_Inv_Nmbr + ' is not in the file.'
  32.         WAIT 'Do you want to continue (Y or N)?' TO Changing
  33.      ELSE
  34.             CLEAR
  35.             @  3,0 SAY '           Entry' + STR(RECNO(),5)
  36.             @  3,30 SAY '     DATE  '+dtoc(Inv_Date)
  37.             @  5,0 SAY 'INVOICE NUMBER ' GET Inv_Nmbr
  38.             @  7,0 SAY '        CLIENT ' GET Client PICTURE '!!!'
  39.             @  8,0 SAY '    JOB NUMBER ' GET Job_Nmbr
  40.             @  9,0 SAY 'TAXABLE AMOUNT ' GET Taxable
  41.             @ 10,0 SAY 'TAXFREE AMOUNT ' GET TaxFree
  42.             @ 11,0 SAY '  P. O. NUMBER ' GET PO_Nmbr PICTURE '!!!!!!!!'
  43.             @ 12,0 SAY '   DESCRIPTION ' GET Descrip PICTURE ;
  44.               '!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!'
  45.             @ 13, 0 SAY '    SALES TAX ' GET Sales_Tax
  46.             READ
  47.             ?
  48.         WAIT 'Do you want to edit any other invoices (Y or N)? ';
  49.                 TO Changing
  50.      ENDIF
  51.       ELSE
  52.          Changing = 'N'
  53.       ENDIF
  54.    ENDIF
  55. ENDDO Changing
  56. RETURN
  57.